package edu.bu.cs673.superkids123;

import javax.swing.JFrame;

import edu.bu.cs673.superkids123.children.controller.AchievementController;
import edu.bu.cs673.superkids123.children.controller.ActivitiesMenuController;
import edu.bu.cs673.superkids123.children.controller.ChildProfileController;
import edu.bu.cs673.superkids123.children.controller.games.ArcheryGameController;
import edu.bu.cs673.superkids123.children.controller.games.ArithmaticGameController;
import edu.bu.cs673.superkids123.children.controller.games.GameResultsController;
import edu.bu.cs673.superkids123.children.controller.games.MatchGameController;
import edu.bu.cs673.superkids123.children.controller.games.NumberMatchingGameController;
import edu.bu.cs673.superkids123.children.controller.games.SubtractionGameController;
import edu.bu.cs673.superkids123.children.controller.lessons.CountingLessonController;
import edu.bu.cs673.superkids123.children.controller.lessons.AddingLessonController;
import edu.bu.cs673.superkids123.children.controller.lessons.LessonResultsController;
import edu.bu.cs673.superkids123.children.view.AchievementView;
import edu.bu.cs673.superkids123.children.view.ActivitiesMenuView;
import edu.bu.cs673.superkids123.children.view.ChildProfileView;
import edu.bu.cs673.superkids123.children.view.games.ArcheryGameView;
import edu.bu.cs673.superkids123.children.view.games.ArithmaticGameView;
import edu.bu.cs673.superkids123.children.view.games.FanFairView;
import edu.bu.cs673.superkids123.children.view.games.GameResultsView;
import edu.bu.cs673.superkids123.children.view.games.MatchGameView;
import edu.bu.cs673.superkids123.children.view.games.NumberMatchingGameView;
import edu.bu.cs673.superkids123.children.view.games.SubtractionGameView;
import edu.bu.cs673.superkids123.children.view.lessons.CountingLessonView;
import edu.bu.cs673.superkids123.children.view.lessons.AddingLessonView;
import edu.bu.cs673.superkids123.children.view.lessons.LessonResultsView;
import edu.bu.cs673.superkids123.common.controller.AuthenticationController;
import edu.bu.cs673.superkids123.common.controller.LoginController;
import edu.bu.cs673.superkids123.common.controller.ParentsLoginController;
import edu.bu.cs673.superkids123.common.view.LoginView;
import edu.bu.cs673.superkids123.common.view.ParentsLoginView;
import edu.bu.cs673.superkids123.parents.controller.AchievementDetailsController;
import edu.bu.cs673.superkids123.parents.controller.CreateChildController;
import edu.bu.cs673.superkids123.parents.controller.ChangeChildController;
import edu.bu.cs673.superkids123.parents.controller.CustomizationController;
import edu.bu.cs673.superkids123.parents.controller.DeleteChildController;
import edu.bu.cs673.superkids123.parents.controller.ManageAchievementsController;
import edu.bu.cs673.superkids123.parents.controller.ReportController;


import edu.bu.cs673.superkids123.parents.controller.CreateParentController;
import edu.bu.cs673.superkids123.parents.controller.EditChildController;
import edu.bu.cs673.superkids123.parents.controller.ParentSettingsController;
import edu.bu.cs673.superkids123.parents.view.AchievementDetailsView;
import edu.bu.cs673.superkids123.parents.view.CreateChildView;
import edu.bu.cs673.superkids123.parents.view.ChangeChildView;
import edu.bu.cs673.superkids123.parents.view.DeleteChildView;
import edu.bu.cs673.superkids123.parents.view.CreateParentView;
import edu.bu.cs673.superkids123.parents.view.EditChildView;
import edu.bu.cs673.superkids123.parents.view.ManageAchievementsView;
import edu.bu.cs673.superkids123.parents.view.CustomizationView;
import edu.bu.cs673.superkids123.parents.view.ParentSettingsView;
import edu.bu.cs673.superkids123.parents.view.ReportView;

public class SuperKids123 extends AbstractFrame {

	public static void main(String[] args) {
		javax.swing.SwingUtilities.invokeLater(new Runnable() {
			@Override
			public void run() {
				new SuperKids123().show();
			}
		});

	}

	@Override
	protected void registerAllViews() {
		views.put(LoginView.class, new LoginView(this));
		views.put(CreateParentView.class, new CreateParentView(this));
		views.put(ParentSettingsView.class, new ParentSettingsView(this));
		views.put(ActivitiesMenuView.class, new ActivitiesMenuView(this));
		views.put(CountingLessonView.class, new CountingLessonView(this));
		views.put(AddingLessonView.class, new AddingLessonView(this));
		views.put(CreateChildView.class, new CreateChildView(this));
		views.put(ChangeChildView.class, new ChangeChildView(this));
		views.put(DeleteChildView.class, new DeleteChildView(this));
		views.put(EditChildView.class, new EditChildView(this));
		views.put(ParentsLoginView.class, new ParentsLoginView(this));
		views.put(LessonResultsView.class, new LessonResultsView(this));
		views.put(GameResultsView.class, new GameResultsView(this));
		views.put(ChildProfileView.class, new ChildProfileView(this));
		views.put(NumberMatchingGameView.class, new NumberMatchingGameView(this));
		views.put(AchievementView.class, new AchievementView(this));
		views.put(ReportView.class, new ReportView(this));
		views.put(ArithmaticGameView.class, new ArithmaticGameView(this));
		views.put(MatchGameView.class, new MatchGameView(this));
		views.put(CustomizationView.class, new CustomizationView(this));
		views.put(FanFairView.class, new FanFairView(this));
		views.put(ManageAchievementsView.class, new ManageAchievementsView(this));
		views.put(AchievementDetailsView.class, new AchievementDetailsView(this));
		views.put(ArcheryGameView.class, new ArcheryGameView(this));
		views.put(SubtractionGameView.class, new SubtractionGameView(this));
	}

	@Override
	protected void registerAllControllers() {
		// Auth controller should always be first
		controllers.put(AuthenticationController.class, new AuthenticationController(this));
		
		controllers.put(LoginController.class, new LoginController(this));
		controllers.put(CreateParentController.class, new CreateParentController(this));
		controllers.put(CreateChildController.class, new CreateChildController(this));
		controllers.put(ChangeChildController.class, new ChangeChildController(this));
		controllers.put(DeleteChildController.class, new DeleteChildController(this));
		controllers.put(ParentSettingsController.class, new ParentSettingsController(this));
		controllers.put(ActivitiesMenuController.class, new ActivitiesMenuController(this));
		controllers.put(CountingLessonController.class, new CountingLessonController(this));
		controllers.put(AddingLessonController.class, new AddingLessonController(this));
		controllers.put(LessonResultsController.class, new LessonResultsController(this));
		controllers.put(GameResultsController.class, new GameResultsController(this));
		controllers.put(ParentsLoginController.class, new ParentsLoginController(this));
		controllers.put(ChildProfileController.class, new ChildProfileController(this));
		controllers.put(NumberMatchingGameController.class, new NumberMatchingGameController(this));
		controllers.put(AchievementController.class, new AchievementController(this));
		controllers.put(EditChildController.class, new EditChildController(this));
		controllers.put(ArithmaticGameController.class, new ArithmaticGameController(this));
		controllers.put(MatchGameController.class, new MatchGameController(this));
		controllers.put(ReportController.class, new ReportController(this));
		controllers.put(CustomizationController.class, new CustomizationController(this));
		controllers.put(ManageAchievementsController.class, new ManageAchievementsController(this));
		controllers.put(AchievementDetailsController.class, new AchievementDetailsController(this));
		controllers.put(ArcheryGameController.class, new ArcheryGameController(this));
		controllers.put(SubtractionGameController.class, new SubtractionGameController(this));
	}

	@Override
	protected JFrame layout() {
		return frame("Super Kids 123", LoginView.class);
	}

}
